<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script type="text/javascript" src="<c:url value="/resources/js/jquery-3.4.1.min.js" />"></script>
<link href="<c:url value="/resources/bootstrap/bootstrap-4.4.1-dist/css/bootstrap.min.css" />" rel="stylesheet">
<script type="text/javascript" src="<c:url value="/resources/bootstrap/bootstrap-4.4.1-dist/js/bootstrap.min.js" />"></script>
<link href="<c:url value="/resources/bootstrap/bootstrap-4.4.1-dist/css/bootstrap.css" />" rel="stylesheet">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"  >
<title>首页</title>
<style type="text/css">
body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.428571429;
  color: #333333;
  background-color: #ffffff;
}
.leftnav{
    margin-top:4px;
}

</style>
</head>
<body>
<div class="container-fluid">
    <div class="row">
        <div class="col-12">
			<nav class="navbar navbar-expand-lg navbar-light bg-light">
			  <a class="navbar-brand" href="#"></a>
			  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarText" aria-controls="navbarText" aria-expanded="false" aria-label="Toggle navigation">
			    <span class="navbar-toggler-icon"></span>
			  </button>
			  <div class="collapse navbar-collapse" id="navbarText">
			    <ul class="navbar-nav mr-auto">
			      <li class="nav-item active">
			        <a class="nav-link" href="#"> <span class="sr-only"></span></a>
			      </li>
			      <li class="nav-item">
			        <a class="nav-link" href="#"></a>
			      </li>
			      <li class="nav-item">
			        <a class="nav-link" href="#"></a>
			      </li>
			    </ul>
			    <span class="navbar-text">
			      ${sessionScope.userInfo.userName }
			    </span>
			  </div>
			</nav>
		</div>
	</div>
</div>
<div class="container-fluid leftnav">
	<div class="row">
		<div class="col-2">
		   <div class="nav flex-column nav-pills" id="v-pills-tab" role="tablist" aria-orientation="vertical">
		     <a class="nav-link active" id="v-pills-messages-tab" data-toggle="pill"  href="#v-pills-messages" role="tab" aria-controls="v-pills-messages" aria-selected="false">项目列表</a>
		     <!-- <a class="nav-link" id="v-pills-settings-tab" data-toggle="pill" href="#v-pills-settings" role="tab" aria-controls="v-pills-settings" aria-selected="false">项目信息维护</a> -->
		   </div>
		</div>
	     <div class="col-10 rightContent">
	       <div class="tab-content" id="v-pills-tabContent">
	         <div class="tab-pane fade show active" id="v-pills-messages" role="tabpanel" aria-labelledby="v-pills-messages-tab" >
                    <iframe   
	                    src="<c:url value="/project/list.do?pageNum=1&pageSize=10" />"                 
	                    scrolling="no" 
	                    name="projectlist"  
	                    id="projectlist" 
	                    width="100%"
						height="1200px"
	                    frameborder="0">
	                 </iframe> 
            </div>
	         <div class="tab-pane fade" id="v-pills-settings" role="tabpanel" aria-labelledby="v-pills-settings-tab">
	                <!--<iframe src="<c:url value="/projectMaintain" />" scrolling="no" name="projectMaintain" id="projectMaintain" width="100%" height="600px" frameborder="0"></iframe>  -->
	         </div>
	       </div>
	     </div>
	</div>
</div>

</body>                     
<script type="text/javascript">

        <c:if test="${empty(sessionScope.userInfo)}">
              alert("请登录后访问");
              window.location.href = "<c:url value='/' />"
        </c:if>

       //  function changeFrameHeight(){
       // 	    var ifm= document.getElementById("projectMaintain");
	   //
       //      if(ifm){
       //          ifm.height= ifm.contentWindow.document.body.scrollHeight;
       //      }
       // 	    ifm= document.getElementById("projectlist");
       // 	    if(ifm){
       //          ifm.height= ifm.contentWindow.document.body.scrollHeight;
       // 	    }
       // 	}
       //  window.onload=function(){
       //      changeFrameHeight();
	   //
       // }
       // 	window.onresize=function(){
       // 	     changeFrameHeight();
	   //
       // 	}
  
</script>
</html>